<?php
/**
 * 获得用户信息动作类
 * @author yaoli<yaoli@pateo.com.cn>
 * @version 1.0 GetUser add by yaoli<yaoli@pateo.com.cn> 
 */
class index extends ActionBase {
	
	private $date = null;
	
	function init(){
		$this->date['page'] = (isset($_REQUEST['page']))?($_REQUEST['page']-1):0;
		

	}
	
	/**
	 * 动作
	 *
	 * @see AActionBase::action()
	 */
	public function action() {
		 $this->template();
		$this->template->display ( 'center.html' );
	}
	
	public function left() {
		$this->template();
		$this->template->display ( 'left.html' );
	}
	
	#路书
	public function roadbook() {
		$this->date['roadbook'] = load_model('roadbook')->getRoadbook($this->date['page']);
		
		 $this->date['count'] = load_model('roadbook')->getRcount('view_roadbook');
		 
		 $this->date['pagecontent'] = fenye(url('index/roadbook')."&page=",$this->date['page']+1,$this->date['count'],PERPAGE);
		
		$this->template();
		$this->template->assign($this->date);
		$this->template->display ( 'roadbook.html' );
	}
	#途径地
	public function way() {
		$this->date['way'] = load_model('way')->getWay($this->date['page']);
		
		$this->date['count'] = load_model('way')->getRcount('view_way');
		
			
		$this->date['pagecontent'] = fenye(url('index/way')."&page=",$this->date['page']+1,$this->date['count'],PERPAGE);
		
		
		$this->template();
		$this->template->assign($this->date);
		$this->template->display ( 'way.html' );
	}
	#兴趣点
	public function point() {
		$this->date['point'] = load_model('point')->getPoint($this->date['page']);
		
		$this->date['count'] = load_model('way')->getRcount('view_point');
		
		$this->date['pagecontent'] = fenye(url('index/way')."&page=",$this->date['page']+1,$this->date['count'],PERPAGE);
		
		$this->template();
		$this->template->assign($this->date);
		$this->template->display ( 'point.html' );
	}

}
